<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <title>添加轮播图</title>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="../../../../elementUI/index.css">
  <link rel="stylesheet" href="../../../../css/index.css">
</head>

<body>
  <div id="app" class="minWidth">
    <el-form :model="form" ref="contract" :rules="rules" inline-message="true" style="width: 100%">
      <div class="table_titel">
        <div class="titel">添加轮播图</div>
      </div>
      <el-descriptions :column="3" border size="small">

        <el-descriptions-item label="轮播图名称">
          <el-form-item prop="Carousel_Chart_Name">
            <el-input v-model.trim="form.Carousel_Chart_Name" placeholder="请输入轮播图名称"></el-input>
          </el-form-item>
        </el-descriptions-item>

        <!-- <el-descriptions-item label="小程序App_ID">
          <el-form-item prop="App_ID">
            <el-select v-model.trim="form.App_ID" placeholder="请选择小程序App_ID" filterable style="width: 100%">
              <el-option v-for="(item,index) in App_ID" :key="index" :label="item.App_Name"
                :value="item.App_ID"></el-option>
            </el-select>
          </el-form-item>
        </el-descriptions-item> -->
        <el-descriptions-item label="链接地址">
          <el-form-item prop="Store_SerialNumber">
            <el-select v-model.trim="form.Carousel_Chart_Path" placeholder="请选择链接地址" filterable style="width: 100%" @change="changePath">
              <el-option v-for="(item,index) in AddressList" :key="index" :label="item.AppID_Path_Name"
                :value="item.AppID_Path"></el-option>
            </el-select>
          </el-form-item>
        </el-descriptions-item>

        <el-descriptions-item label="门店名称">
          <el-form-item prop="Store_SerialNumber">
            <el-input v-model.trim="form.url" placeholder="请选择类目链接地址"></el-input>
            <!-- <el-select :disabled="disabled" v-model.trim="form.Store_SerialNumber" placeholder="请选择销售订单" filterable
              style="width: 100%">
              <el-option v-for="(item,index) in shop" :key="index" :label="item.Store_Name"
                :value="item.Store_SerialNumber"></el-option>
            </el-select> -->
          </el-form-item>
        </el-descriptions-item>

        <el-descriptions-item label="商品封面">
          <el-form-item prop="pic">
            <div class="preview" v-show="form.Picture_URL">
              <el-image class="el-upload-list__item-thumbnail" style="width: 148px; height: 148px"
                :src="DomainIMG + form.Picture_URL" fit="contain"></el-image>
              <span class="el-upload-list__item-actions">
                <span @click="handlePictureCardPreview(form.Picture_URL)"><i class="el-icon-zoom-in"></i></span>
                <span @click="handleRemove"><i class="el-icon-delete"></i></span>
              </span>
            </div>
            <el-upload v-show="!form.Picture_URL" class="upload-demo" :show-file-list="false" list-type="picture-card"
              action="" accept="image/*" :before-upload="uploadFront">
              <i slot="default" class="el-icon-plus"></i>
              <div class="el-upload__tip" slot="tip">上传正方形图片，且大小不超过120k</div>
            </el-upload>
          </el-form-item>
        </el-descriptions-item>
        <el-descriptions-item v-if="form.Carousel_Chart_Type == '0'" label="销售价格单">
          <el-form-item prop="Sales_Unit_Price_Detail_SerialNumber">
            <el-select @change="ChangeSales" v-model.trim="form.Sales_Unit_Price_Detail_SerialNumber"
              placeholder="请选择销售价格单" filterable style="width: 100%">
              <el-option v-for="(item,index) in SalesInfo" :key="index" :label="item.Article_Name"
                :value="item.Sales_Unit_Price_Detail_SerialNumber"></el-option>
            </el-select>
          </el-form-item>
        </el-descriptions-item>
        <!-- <el-descriptions-item label="路径">
          <el-form-item prop="Store_SerialNumber">
            <el-select  v-model.trim="form.url" placeholder="请选择路径" filterable
              style="width: 100%">
              <el-option v-for="(item,index) in AddressList" :key="index" :label="item.AppID_Path_Name"
                :value="item.AppID_Path"></el-option>
            </el-select>
          </el-form-item>
        </el-descriptions-item> -->

      </el-descriptions>

      <el-dialog :visible.sync="dialogVisible">
        <img width="100%" :src="DomainIMG + dialogImageUrl" alt="">
      </el-dialog>

      <el-form-item class="form-operation">
        <el-button @click="window.history.back()">返回</el-button>
        <el-button type="primary" :loading="loading" @click="submitForm('contract')">提交</el-button>
      </el-form-item>
    </el-form>
  </div>
  <script type="text/javascript" src="../../../../js/jquery-3.6.0.min.js"></script>
  <script type="text/javascript" src="../../../../js/jquery.cookie.js"></script>
  <script type="text/javascript" src="../../../../js/vue.min.js"></script>
  <script type="text/javascript" src="../../../../elementUI/index.js"></script>
  <script type="text/javascript" src="../../../../js/compressor.js"></script>
  <script type="text/javascript" src="../../../../js/utils.js"></script>
  <script type="text/javascript" src="../../../../js/ID_Validity.js"></script>
  <script type="text/javascript" src="./js/Edit.js"></script>
</body>

</html>